package com;

import java.util.Scanner;

/**
 * @description:
 * @author: Peng Jiwei
 * @create :2021/9/29-15:21
 */
public class Test2 {
    public static void main(String[] args) {
        Scanner input = new Scanner(System.in);
        int n = input.nextInt();
        System.out.println("一共有："+cal(n)+" 种走台阶的方法");
        System.out.println("Helo world!");
    }

    public static int cal(int n){
        if(n < 0){
            return 0;
        }
        else if(n == 0){
            return 1;
        }
        else {
            return cal(n-1)+cal(n-2)+cal(n-3);
        }
    }
}
